#region License
/* ---------------------------------------------------------------- *
 *
 * This file is part of the Xcoordination Application Space
 * ("XcoAppSpace") http://www.xcoordination.com
 *
 * Copyright (C) 2009 Xcoordination http://www.xcoordination.com
 *
 * XcoAppSpace is free software; you can redistribute it and/or
 * modify it under the terms of version 2 of the GNU General
 * Public License as published by the Free Software Foundation.
 *
 * XcoAppSpace is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program. If not, see http://www.gnu.org/licenses/
 * or write to the Free Software Foundation, Inc., 51 Franklin
 * Street, Fifth Floor, Boston, MA 02110-1301, USA.
 *
 * ---------------------------------------------------------------- */
#endregion

using System;
#if !MF
using System.Runtime.Serialization;
#endif

namespace XcoAppSpaces.Contracts.Exceptions
{
	/// <summary>
	/// XcoException is the base class for all Exceptions thrown in XcoAppSpaces.
	/// </summary>
	public class XcoException : Exception
	{
		/// <summary>
		/// Creates a new XcoException.
		/// </summary>
		public XcoException()
		{
		}

		/// <summary>
		/// Creates a new XcoException.
		/// </summary>
		/// <param name="message">The error message.</param>
		public XcoException(String message)
			: base(message)
		{
		}

		/// <summary>
		/// Creates a new XcoException.
		/// </summary>
		/// <param name="message">The error message.</param>
		/// <param name="innerException">Inner Exception.</param>
		public XcoException(String message, Exception innerException) 
			: base(message, innerException) 
		{
		}

#if !PocketPC && !SILVERLIGHT && !MF && !PORTABLE
		/// <summary>
		/// Creates a new XcoException. Needed for serialization.
		/// </summary>
		/// <param name="info">SerializationInfo for handling type-specific serialization information.</param>
		/// <param name="context">StreamingContext for handling type-specific serialization information.</param>
		protected XcoException(SerializationInfo info, StreamingContext context)
			: base(info, context)
		{
			// Implement type-specific serialization constructor logic.
		}
#endif
	}
}
